package org.yys.consumer.listener;

import org.apache.rocketmq.spring.annotation.MessageModel;
import org.apache.rocketmq.spring.annotation.RocketMQMessageListener;
import org.apache.rocketmq.spring.core.RocketMQListener;
import org.springframework.stereotype.Component;

@Component
@RocketMQMessageListener(topic = "modeTopic",consumerGroup = "broadcast-consumer-group",messageModel = MessageModel.BROADCASTING)
public class BroadcastCListener implements RocketMQListener<String> {

    @Override
    public void onMessage(String message) {
        System.out.println(message+","+this.getClass().getName());
    }
}
